package com.kejizhentan.utils;

import org.springframework.util.StringUtils;

public class TestHttps {
    public static void main(String[] args) throws Exception {
        //获取授权临时票据
        System.out.println("微信授权服务器回调。。。。。。");
        //使用code和appid以及appscrect换取access_token
        StringBuffer baseAccessTokenUrl = new StringBuffer()
                .append("https://apis.juhe.cn/fapigw/worldcup2022/schedule")
                .append("?key=%s")
                .append("&type=%s");
        //使用%s占位
        String accessTokenUrl = String.format(baseAccessTokenUrl.toString(),"73347fc64db9be3c2cc47b3005b3bc6a",6);

        String result = null;
        result = HttpClientUtils.get(accessTokenUrl);
        System.out.println(result);
    }
}
